/* 清除所有元素的内外边距和默认样式 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-style: normal;
  font-weight: normal;
  text-decoration: none;
  list-style: none;
  border: 0;
}

html,
body {
  scroll-behavior: smooth;
}

/* 设置默认字体和颜色 */
body {
  font-family: 'Microsoft YaHei', 'Heiti SC', 'tahoma', 'arial', 'Hiragino Sans GB', '宋体', sans-serif;
  color: var(--primary-font);
  background-color: var(--body-bg);
  font-size: 12px;
  line-height: 1;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: --scroll-position-delayed .15s linear;
  // 定义两个自定义属性，用于页面滚动时动画实现
  --scroll-velocity: calc(var(--scroll-position) - var(--scroll-position-delayed));
  --scroll-dynamic: calc(var(--scroll-velocity) / var(--scroll-velocity));
}

// 移动端点击遮罩去除
div {
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  -ms-tap-highlight-color: rgba(0, 0, 0, 0);
}

#app {
  position: relative;
  width: 100vw;
  height: 100vh;
}

// 美化滚动条
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-horizontal {
  display: none;
}

::-webkit-scrollbar-track {
  width: 6px;
  background-color: var(--body-bg);
  -webkit-border-radius: 2em;
  -moz-border-radius: 2em;
  border-radius: 2em;
}

::-webkit-scrollbar-thumb {
  background-color: var(--primary-bg);
  background-clip: padding-box;
  min-height: 28px;
  -webkit-border-radius: 2em;
  -moz-border-radius: 2em;
  border-radius: 2em;
  transition: background-color .3s;
  cursor: pointer;
}


/* 设置a标签的默认样式 */
a {
  text-decoration: none;
}

/* 图片和视频不超出其容器 */
img,
video {
  max-width: 100%;
  height: auto;
  vertical-align: middle;
}

/* 设置链接样式 */
a {
  color: #666;
  text-decoration: none;
  font-size: 15px;
}

a:hover {
  color: #002c6e;
}

/* 设置输入框和按钮样式 */
input,
button {
  font-family: inherit;
  border: none;
  outline: none;
}

button {
  cursor: pointer;
  font-size: 14px;
  padding: 4px 10px;
  border-radius: 15px;
}

/* 设置表格样式 */
table {
  border-collapse: collapse;
  width: 100%;
  font-size: 14px;

  td,
  th {
    padding: 8px 0 8px 8px;
  }

  th {
    font-size: 16px;
    padding: 10px 0;
    font-weight: 600;
  }
}

@media screen and (max-width: 768px) {
  a {
    font-size: .9375rem;
  }

  button {
    min-width: 6.25rem;
    font-size: .875rem;
    padding: .25rem .625rem;
    border-radius: .9375rem;
  }

  table {
    font-size: .875rem;

    td,
    th {
      padding: .5rem 0 .5rem .5rem;
    }

    th {
      font-size: 1rem;
      padding: .625rem 0;
    }
  }
}

/* 清除浮动 */
.clearfix::after {
  content: "";
  display: table;
  clear: both;
}

.clearfix {
  zoom: 1;
}

/* 隐藏元素 */
.hide,
.none {
  display: none;
}
